/**
 * Company : Thai Informatic System Co., Ltd.
 * Created By : Dr.Tree
 * Created On : Feb 10, 2012  2:23:48 PM 
 * e-Mail : chatree@tis.co.th
 * Mobile Phone : (+66) 087-921-5115
 * Package Name : jpa.service.common
 * File Name : JPAServiceIntrerface.java
 * TODO
 */
package jpa.service.synchro.common;

import java.util.List;
import java.util.Map;
import jpa.entitys.synchro.common.CommonEntity;

/**
 * @author chatree
 *
 */
public interface JPAServiceIntrerface {
	
	CommonEntity find(String id) throws Exception;
	
	CommonEntity find(String id, String NamedQuery) throws Exception;
		
	List<CommonEntity> find(String id, Map<String,Object> mapWhereValue) throws Exception;
	
	CommonEntity inserted(CommonEntity object) throws Exception;
		
	List<CommonEntity> inserted(List<CommonEntity> object_lst) throws Exception;
		
	CommonEntity updated(CommonEntity object) throws Exception;
		
	List<CommonEntity> updated(List<CommonEntity> object_lst) throws Exception;
	
	CommonEntity deleted(CommonEntity object) throws Exception;

	List<CommonEntity> deleted(List<CommonEntity> object_lst) throws Exception;
		
	void destroyed(CommonEntity object) throws Exception;
	
	void destroyed(List<CommonEntity> object_lst) throws Exception;
	
	List<Object[]> findsql(String sql) throws Exception;
}
